package com.android.pa;

import java.util.Calendar;

public class FluidTask extends Task
{

	private static final long serialVersionUID = 1L;
	
	private long 			_duration;
	private Calendar 		_deadline;

	/**
	 * Instantiates the task Description as ";"+String.valueOf(_duration)+";"+String.valueOf(_deadline),
	 * So the description holds the duration and the deadline as well,
	 * separated by ';'.
	 * SetDescription(String) concatenates the given String to this artificial description,
	 * so it can have the form of: "Write a paper;140000;112874000000" or ";140000;11287400000"
	 * if no one has called setDescription(String).
	 * @param title String, the title of the task.
	 * @param dur duration of the Task, in milliseconds.
	 * @param deadline deadline of Task, in Calendar format.
	 * @param location String, location of task.
	 */
	public FluidTask(String title, long dur, Calendar deadline, String location)
	{
		super(title, location, true);
		_duration = dur;
		_deadline = deadline;
	}

	public long getDuration()
	{
		return _duration;
	}

	public void setDuration(long dur)
	{
		_duration = dur;
	}

	public void setDeadline(Calendar deadline)
	{	
		_deadline = deadline;
	}

	public Calendar getDeadline()
	{
		return _deadline;
	}

}